const Router = require('koa-router')
const user = require('./users')
const project = require('./project')
const f = require('./files')
const apiList = require('./apiList')
const api = require('./api')

const router = Router()

router.get('/', async (ctx, next) =>{
  ctx.body = 'this is a users response!'
})
// routes表示的是路由的嵌套处理
router.use(user.routes(), user.allowedMethods())
router.use(project.routes(), project.allowedMethods())
router.use(f.routes(), f.allowedMethods())
router.use(apiList.routes(), apiList.allowedMethods())
router.use(api.routes(), api.allowedMethods())

module.exports = router